<template>
  <div>
    <div class="top">
      <van-nav-bar
        title="信息列表"
        left-text="返回"
        right-text=""
        left-arrow
        @click-left="() => this.$router.go(-1)"
      />
    </div>
    <div class="body">
      <div
        v-for="a in data"
        :key="a"
        class="my-van-field flex"
        @click="Details"
      >
        <div>
          <div>上海市嘉定区</div>
          <div>
            <span class="name">{{ "张三" + a }}</span>
            <span class="time">2020-05-22 10:26:14</span>
          </div>
        </div>
        <div>已分配</div>
        <van-icon name="arrow" size="20" />
      </div>
      <van-divider v-if="data.length == 0">暂无数据</van-divider>
    </div>
  </div>
</template>
<script>
export default {
  data() {
    return {
      data: [1, 2, 3, 4, 5],
    };
  },
  methods: {
    Details() {
      this.$router.push("/InformationList/Details");
    },
  },
};
</script>
<style lang="scss" scoped>
.body {
  width: 100%;
  height: 100%;
}
.flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.name {
  color: #187615;
}
.time {
  color: #0e08b4;
  margin-left: 20px;
}
</style>
